<include file="public/header" title="修改身份证号" body=""/>
<include file="public/header_nav" title="修改身份证号"  href="{:U('Mobile/User/userinfo')}"/>
    <div class="loginsingup-input singupphone findpassword">
        <form action="{:U('Mobile/User/userinfo')}" method="post">
            <div class="content30">
                <div class="lsu bk">
                    <span>身份证号</span>
                    <input type="text" name="idcard" value="{$user.idcard}" placeholder="请输入您的身份证号" onBlur="checkszf(this);"/>
                </div>
                <div class="lsu submit">
                    <input type="submit" name="" id="" value="确认修改" />
                </div>
            </div>
        </form>
    </div>
<script type="text/javascript">
function checkszf(e){
    var reg=/^(^[1-9]\d{7}((0\d)|(1[0-2]))(([0|1|2]\d)|3[0-1])\d{3}$)|(^[1-9]\d{5}[1-9]\d{3}((0\d)|(1[0-2]))(([0|1|2]\d)|3[0-1])((\d{4})|\d{3}[Xx])$)$/;
    if(!reg.test($(e).val())){
        alert('身份证号格式错误');
        $(e).val('');
    }
}
</script>
</body>
</html>
